<template>
    <el-result title="404" subTitle="抱歉，请求错误">
    <template slot="icon">
        <el-image src="https://shadow.elemecdn.com/app/element/hamburger.9cf7b091-55e9-11e9-a976-7f4d0b07eef6.png"></el-image>
    </template>
    <template slot="extra">
        <el-button type="warning" size="medium" @click="toLogin">重新登录</el-button>
        <el-button type="primary" size="medium" @click="toBack">返回</el-button>
    </template>
    </el-result>
</template>
<script>
import { userLogout } from '@/utils/auth'
export default {
  components: {},
  data () {
    return {}
  },
  watch: {
    $route: {
      handler: function (route) {
        console.log('404:', route)
      }
    }
  },
  methods: {
    toLogin () {
      userLogout()
    },
    toBack () {
      this.$router.go(-1)
    }
  }
}
</script>

<style lang="scss" scoped>
</style>
